#ifndef LANGUAGESTRATEGY_H
#define LANGUAGESTRATEGY_H

#include "textcontext.h"
#include "textlabel.h"

/****************************************************
  Base class of languages' strategy. Now it has
  subclasses: ChineseStrategy and EnglishStrategy.
 ****************************************************/
class LanguageStrategy
{
public:
    LanguageStrategy();

    // Set text context
    void setContext(TextContext * context){
        _context = context;
    }

    // Whether the given position should start a new line
    virtual int getCharsBeforeNewLine(XCHAR *, int, int) = 0;

protected:
    TextContext * _context;
};

#endif // LANGUAGESTRATEGY_H
